//
//  BaseViewController.m
//  Coding_My
//
//  Created by showXxie on 2017/8/18.
//  Copyright © 2017年 sooxie. All rights reserved.
//

#import "BaseViewController.h"
#import "User.h"
@interface BaseViewController ()

@end

@implementation BaseViewController

- (void)tabBarItemClicked{
    DebugLog(@"\ntabBarItemClicked : %@", NSStringFromClass([self class]));
    
//    [self test];
    
}

- (void)test {
    
    void(^block)() = ^{
        printf("Hello, World!\n");
    };
    
    block();
    ^{printf("Hello, World!\n"); } ();
    
}


- (void)viewDidLoad {
    [super viewDidLoad];
    
    
    
//    NSMutableDictionary *params = @{@"account": @"sooxie",
//                                    @"password" : [@"38433859xie" sha1Str],
//                                    @"remember_me" :  @"true"}.mutableCopy;
//    
//    [[NetAPIManager manager] loginPath:@"api/v2/account/login" Params:params andBlock:^(id data, NSError *error) {
//        
//        
//        
//        
//        
//        
//        
//        
//        
//        
//    }];

    
    self.view.backgroundColor = kColorTableSectionBg;
    
    // 1.创建信号

//    RACSubject *subject = [RACSubject subject];
    
    // 2.订阅信号
//    [subject subscribeNext:^(id x) {
//        // block调用时刻：当信号发出新值，就会调用.
//        NSLog(@"第一个订阅者%@",x);
//    }];
//    
//    [subject subscribeNext:^(id x) {
//        // block调用时刻：当信号发出新值，就会调用.
//        NSLog(@"第二个订阅者%@",x);
//    }];
//    
//    // 3.发送信号
//    [subject sendNext:@"1"];
    
    
//    NSArray *numbers = @[@1,@2,@3,@4];
//
//    [numbers.rac_sequence.signal subscribeNext:^(id x) {
//        NSLog(@"%@",x);
//
//    }];

}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
